package com.iscreen.entities;
import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Embeddable;

@Embeddable
public class SectorsPK implements Serializable {
	@Column(name="SECTOR_CODE")
	private String sectorCode;

	@Column(name="SUB_SECTOR_CODE")
	private String subSectorCode;

	private static final long serialVersionUID = 1L;

	public SectorsPK() {
		super();
	}

	public String getSectorCode() {
		return this.sectorCode;
	}

	public void setSectorCode(String sectorCode) {
		this.sectorCode = sectorCode;
	}

	public String getSubSectorCode() {
		return this.subSectorCode;
	}

	public void setSubSectorCode(String subSectorCode) {
		this.subSectorCode = subSectorCode;
	}

	@Override
	public boolean equals(Object o) {
		if (o == this) {
			return true;
		}
		if ( ! (o instanceof SectorsPK)) {
			return false;
		}
		SectorsPK other = (SectorsPK) o;
		return this.sectorCode.equals(other.sectorCode)
			&& this.subSectorCode.equals(other.subSectorCode);
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int hash = 17;
		hash = hash * prime + this.sectorCode.hashCode();
		hash = hash * prime + this.subSectorCode.hashCode();
		return hash;
	}

}
